home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The PC-SIG Library 10
/
The PC-Sig Library - Shareware for the IBM PC and Compatibles (PC-SIG)(Tenth Edition Disks 1-2804)(1991).iso
/
PC_SIGCD
/
07
/
3
/
DISK0738.ZIP
/
COPYFILE.BAT
< prev
next >
Wrap
DOS Batch File
|
1988-01-01
|
7KB
|
197 lines
echo off
cls
rem COPYFILE.BAT
rem EasyMenu Installation Procedure
rem (C) 1986-88 by EasyMenu Publishing
rem %1 = A to H
rem %2 = install directory
if exist TEMP.BAT del TEMP.BAT
if "%1"=="" install
if "%2"=="" install
if "%2" == "\" install
if "%3"=="" goto start
if %3 == UPDATE goto update
rem
:start
rem
if exist AUTOEXEC.NEW goto copyfile
:confirm
cls
echo ┌ Confirm Directory to install ───────────────────────────────────────────┐
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo ┌───────────────┐
echo │ DRIVE │ %1:
echo └───────────────┘
echo ┌───────────────┐
echo │ SUB-DIRECTORY │ %2
echo └───────────────┘
echo ┌───────────────┐
echo │ BATCH START │ %2.BAT ROOT directory
echo └───────────────┘
echo
echo ╔════╗ ╔══════════════════════════════════════════╗
echo ║ Y ║ ║ Yes. Continue INSTALL ║
echo ╚════╝ ╚══════════════════════════════════════════╝
echo ┌────┐ ┌──────────────────────────────────────────┐
echo │ N │ │ No. │
echo └────┘ └──────────────────────────────────────────┘
echo
ask YNQ
cls
if errorlevel 3 goto aborted
if errorlevel 2 goto aborted
rem
:copyfile
rem
cls
echo ┌ Create Sub-Directory ───────────────────────────────────────────────────┐
echo │ │
echo │ WORKING . . . │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo creating sub-directory %1:%2
mkdir %1:%2
rem CLONE OR NOT
rem
if exist 0.MU goto CLONE
rem
:CLONEYES
cls
echo ┌ Copy Sample Menus ──────────────────────────────────────────────────────┐
echo │ │
echo │ WORKING . . . │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo copying Menus and Help Files to %1:%2
copy *.mh %1:%2 > NUL
copy *.m %1:%2 > NUL
rem *** INSTALL FROM HARD DRIVE ***
if exist 0.MU echo copying User file to %1:%2
if exist 0.MU copy 0.MU %1:%2 > NUL
if exist 0.MU cls
if exist 0.MU goto update
:CLONENO
rem
goto update
rem
:clone
rem Copy current menus and config or Start fresh
cls
echo ┌ Clone System ───────────────────────────────────────────────────────────┐
echo │ │
echo │ Copy existing Menus ? │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo Drive %1:
echo Directory %2.BAT
echo
echo ╔════╗ ╔══════════════════════════════════════════╗
echo ║ N ║ ║ No. Fresh "MAIN" Menu. ║
echo ╚════╝ ╚══════════════════════════════════════════╝
echo ┌────┐ ┌──────────────────────────────────────────┐
echo │ Y │ │ Yes. Copy all menus and help files. │
echo └────┘ └──────────────────────────────────────────┘
echo
ask YNQ
cls
if errorlevel 3 goto aborted
if errorlevel 2 goto cloneno
if errorlevel 1 goto cloneyes
rem
:update
rem
echo Checking for old files . . . IGNORE "file not found" MESSAGE(S)
del %1:%2\options.* > NUL
del %1:%2\control.com > NUL
del %1:%2\swapdir.com > NUL
cls
echo ┌ Copy System Files ──────────────────────────────────────────────────────┐
echo │ │
echo │ WORKING . . . │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo copying PROGRAM files to %1:%2
copy easymenu.bat %1:%2 > NUL
copy options.exe %1:%2 > NUL
copy *.mhh %1:%2 > NUL
copy control.exe %1:%2 > NUL
echo copying EDITOR files to %1:%2
copy edithelp.* %1:%2 > NUL
copy editerr.msg %1:%2 > NUL
echo creating STARTUP file %1:%2.BAT in ROOT directory %1:\
echo %1: > %1:%2.bat
echo CD %2 >> %1:%2.bat
echo EASYMENU %%1 %%2 %%3 >> %1:%2.bat
if not exist AUTOEXEC.NEW cls
if not exist AUTOEXEC.NEW goto multi
copy %1:%2.bat %1:\menu.bat > NUL
copy %1:%2.bat %1:\m.bat > NUL
echo copying INSTALL procedures
copy install.bat %1:%2 > NUL
copy setup.bat %1:%2 > NUL
copy copyfile.bat %1:%2 > NUL
copy swapdir.exe %1:%2 > NUL
copy ask.com %1:%2 > NUL
cls
rem
:startem
rem
cls
echo ┌ Start Option ───────────────────────────────────────────────────────────┐
echo │ │
echo │ Would you like to start EasyMenu NOW? │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo ┌────┐ ┌──────────────────────────────────────────┐
echo │ N │ │ No. Leave disk in drive. │
echo └────┘ └──────────────────────────────────────────┘
echo ╔════╗ ╔══════════════════════════════════════════╗
echo ║ Y ║ ║ Yes. Remove disk AFTER EasyMenu starts. ║
echo ╚════╝ ╚══════════════════════════════════════════╝
echo
ask YNQ
cls
if errorlevel 3 goto aborted
if errorlevel 2 install
%1:
CD %2
EASYMENU
rem
:multi
rem
cls
echo ┌ Install Again ──────────────────────────────────────────────────────────┐
echo │ │
echo │ INSTALL another user ? │
echo │ │
echo └─────────────────────────────────────────────────────────────────────────┘
echo
echo Drive %1:
echo Batch %2.BAT
echo
echo ╔════╗ ╔══════════════════════════════════════════╗
echo ║ N ║ ║ No. ║
echo ╚════╝ ╚══════════════════════════════════════════╝
echo ┌────┐ ┌──────────────────────────────────────────┐
echo │ Y │ │ Yes. Start again. │
echo └────┘ └──────────────────────────────────────────┘
echo
ask YNQ
cls
if errorlevel 3 goto aborted
if errorlevel 2 goto done
install
rem
:aborted
rem
install
rem
:done
rem